import request from "@/utils/request";

// 查询物料出仓列表
export function listWhStorehouseOut(query) {
  return request({
    url: "wh/storehouseOut/list",
    method: "get",
    params: query,
  });
}

// 查询物料出仓详细
export function getWhStorehouseOut(id) {
  return request({
    url: "wh/storehouseOut/" + id,
    method: "get",
  });
}

// 新增物料出仓
export function addWhStorehouseOut(data) {
  return request({
    url: "wh/storehouseOut",
    method: "post",
    data: data,
  });
}

// 修改物料出仓
export function updateWhStorehouseOut(data) {
  return request({
    url: "wh/storehouseOut",
    method: "put",
    data: data,
  });
}

// 删除物料出仓
export function delWhStorehouseOut(id) {
  return request({
    url: "wh/storehouseOut/" + id,
    method: "delete",
  });
}
// 物料出仓确认
export function confirmOutStorehouse(data) {
  return request({
    url: `wh/storehouseOut/confirmOutWarehouse`,
    method: "post",
    data,
  });
}
// 取消出仓
export function cancelOutWarehouse(data) {
  return request({
    url: `wh/storehouseOut/cancelOutWarehouse`,
    method: "post",
    data,
  });
}
